﻿using System.Windows.Controls;

namespace SHomeWorkshop.LunarPresentation.Expressions
{
    /// <summary>
    /// 这是一个中间类。
    /// 是为“要嵌入子面板的控件”准备的包装类——但不直接包括子面板。
    /// 为使公式中可以嵌入子面板或其它内容，此类的Child是一个StackPanel，
    /// </summary>
    public abstract class StackPanelExpression : Expression
    {
        public StackPanelExpression(SubPanel rootPanel, SubPanel parentPanel, Editor editor)
            : base(rootPanel, parentPanel, editor)
        {
            this.basePanel = new StackPanel();
            //this.basePanel.Focusable = false;

            this.mainBorder.Child = basePanel;
        }

        protected StackPanel basePanel;

        public StackPanel BasePanel
        {
            get { return basePanel; }
        }

        protected override void BuildChildren()
        {
            base.BuildChildren();
        }
    }
}
